Is PHP decimal calculation too boring? If (0.030! = (0.530-0.500 + 0 + 0 ))
{
$ S = 0.530-0.500 + 0 + 0;
$ S = 0.03-$ s;
}
Which is not equal ??
Not 0 After subtraction
Is PHP an alien computing method?
Reply to discussion (solution)
Please
Php code intval (0.7 + 0.1) * 10) php code
intval((0.7+0.1)*10) Reply content: This is related to the decimal representation of the computer,
Generally, decimal places use floating point numbers.
:
Floating Point in Computer
A floating point
Get data type: If you want to see the value and type of an expression, use var_dump ().If you just want an easy-to-read type of expression for debugging, use GetType ().To view a type, do not use GetType () and use the Is_type () function.Convert
PHP code
Reply content:This is related to the fractional representation of the computer,
Typically, decimals are used as floating-point numbers
Indicated by:
floating-point numbers in a computer
Floating point refers to a number with
This article analyzes the differences between float and integer data types in php and the insufficient data length in that case. The value can only be True or False. when other types are converted to the boolean type, the following values are
This article analyzes the differences between float and integer data types in php and the insufficient data length in that case. the value can only be True or False. when other types are converted to the boolean type... this article analyzes the
This article analyzes the usage differences between floating-point (float) and integer (integer) data types in PHP and, in that case, insufficient data lengths.
The value can only be true or false, and when other types are converted to Boolean, the
This article analyzes the differences between float and integer Data Types in php and the insufficient data length in that case.
The value can only be True or False. When other types are converted to the boolean type, the following values are
Basic grammar knowledge points for getting started with PHP programming, basic syntax for getting started with programming
First, what is PHP
PHP, or "Php:hypertext preprocessor", is an open-source universal scripting language that is widely used,
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.